SUPPORT / SAMPLES & SAS NOTES
 

Support

Problem Note 65822: The METALIB procedure returns "ERROR: CLI error trying to establish connection" when you use the CONOPTS option in library definitions in the metadata

DetailsAboutRate It

When the CONOPTS= LIBNAME statement option is provided in the Option(s) to be appended property value for a library in the metadata, the METALIB Procedure might return the following message:

ERROR: CLI error trying to establish connection. 

This error is followed by information specific to the database from which you are registering or updating table metadata.

The error occurs because PROC METALIB does not include the CONOPTS option when connecting to the database.

Here is an example from SAS® Management Console that shows the SSL mode that is required for PostgreSQL.

pg properties

Use either of the following methods to work around the problem:

  • Write the PROC METADATA code and append the connection options within the DBAUTH statement. Here is an example of the step:   
proc metalib; 
omr (LIBRARY="PG"); 
REPORT(type = summary out = "tab_info"); 
dbauth(DBUSER="myusr1;sslmode=require" DBPASSWORD="mypw1" ); 
SELECT ("CUSTOMER" ); 
FOLDER = "/Shared Data/Libraries/PG Library"; 
run;
 
  • If your database library is accessed via ODBC, then you can specify the connection option in the ODBC DSN definition in the ODBC.ini file. For example, setting these name/value pairs should turn on TLS:
[mydsn]
...
EncryptionMethod=1
ValidateServerCertificate=0
LoginTimeout=30
SSLLibName=/usr/lib64/libssl.so
CryptoLibName=/usr/lib64/libcrypto.so


Operating System and Release Information

Product FamilyProductSystemProduct ReleaseSAS Release
ReportedFixed*ReportedFixed*
SAS SystemBase SASz/OS9.4_M49.4_M79.4 TS1M49.4 TS1M7
z/OS 64-bit9.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft® Windows® for x649.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows 8 Enterprise 32-bit9.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows 8 Enterprise x649.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows 8 Pro 32-bit9.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows 8 Pro x649.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows 8.1 Enterprise 32-bit9.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows 8.1 Enterprise x649.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows 8.1 Pro 32-bit9.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows 8.1 Pro x649.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows 109.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows Server 20089.4_M49.4 TS1M4
Microsoft Windows Server 2008 R29.4_M49.4 TS1M4
Microsoft Windows Server 2008 for x649.4_M49.4 TS1M4
Microsoft Windows Server 2012 Datacenter9.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows Server 2012 R2 Datacenter9.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows Server 2012 R2 Std9.4_M49.4_M79.4 TS1M49.4 TS1M7
Microsoft Windows Server 2012 Std9.4_M49.4_M79.4 TS1M49.4 TS1M7
Windows 7 Enterprise 32 bit9.4_M49.4_M79.4 TS1M49.4 TS1M7
Windows 7 Enterprise x649.4_M49.4_M79.4 TS1M49.4 TS1M7
Windows 7 Home Premium 32 bit9.4_M49.4_M79.4 TS1M49.4 TS1M7
Windows 7 Home Premium x649.4_M49.4_M79.4 TS1M49.4 TS1M7
Windows 7 Professional 32 bit9.4_M49.4_M79.4 TS1M49.4 TS1M7
Windows 7 Professional x649.4_M49.4_M79.4 TS1M49.4 TS1M7
Windows 7 Ultimate 32 bit9.4_M49.4_M79.4 TS1M49.4 TS1M7
Windows 7 Ultimate x649.4_M49.4_M79.4 TS1M49.4 TS1M7
64-bit Enabled AIX9.4_M49.4_M79.4 TS1M49.4 TS1M7
64-bit Enabled Solaris9.4_M49.4_M79.4 TS1M49.4 TS1M7
HP-UX IPF9.4_M49.4_M79.4 TS1M49.4 TS1M7
Linux for x649.4_M49.4_M79.4 TS1M49.4 TS1M7
Solaris for x649.4_M49.4_M79.4 TS1M49.4 TS1M7
* For software releases that are not yet generally available, the Fixed Release is the software release in which the problem is planned to be fixed.